home *** CD-ROM | disk | FTP | other *** search
- on scrollBitmap vDirection
- global gStartPosition
- if vDirection = 1 then
- set vBitmapSprite to the clickOn - 1
- else
- set vBitmapSprite to the clickOn - 2
- end if
- if the puppet of sprite vBitmapSprite = 0 then
- set gStartPosition to the locV of sprite vBitmapSprite
- puppetSprite(vBitmapSprite, 1)
- end if
- set vHeight to the height of sprite vBitmapSprite
- set vScrollAmount to 100
- set vUpperLimit to gStartPosition + vScrollAmount - vHeight
- set vLowerLImit to gStartPosition
- if the puppet of sprite vBitmapSprite = 1 then
- if (the locV of sprite vBitmapSprite + (vScrollAmount * vDirection)) <= vUpperLimit then
- set the locV of sprite vBitmapSprite to vUpperLimit
- else
- if (the locV of sprite vBitmapSprite + (vScrollAmount * vDirection)) >= vLowerLImit then
- set the locV of sprite vBitmapSprite to vLowerLImit
- else
- set the locV of sprite vBitmapSprite to the locV of sprite vBitmapSprite + (vScrollAmount * vDirection)
- end if
- end if
- end if
- end
-